package com.sskj.mine.ui.activity;


import android.text.Html;
import android.widget.TextView;

import com.alibaba.android.arouter.facade.annotation.Route;
import com.sskj.common.base.App;
import com.sskj.lib.RConfig;
import com.sskj.lib.base.BaseActivity;
import com.sskj.mine.R;
import com.sskj.mine.R2;
import com.sskj.mine.bean.AboutUsBean;
import com.sskj.mine.presenter.AboutUsActivityPresenter;

import butterknife.BindView;

@Route(path = RConfig.MINE_ABOUT_US)//关于我们
public class AboutUsActivity extends BaseActivity<AboutUsActivityPresenter> {

    @BindView(R2.id.tvService)
    TextView tvService;
    @BindView(R2.id.tvEmail)
    TextView tvEmail;
    @BindView(R2.id.tv_content)
    TextView tvContent;

    @Override
    protected int getLayoutResId() {
        return R.layout.mine_activity_about_us;
    }

    @Override
    public AboutUsActivityPresenter getPresenter() {
        return new AboutUsActivityPresenter();
    }

    @Override
    protected void initView() {
        setTitle(App.INSTANCE.getString(R.string.mineAboutUsActivity0));
    }

    @Override
    protected void initData() {
        mPresenter.getData();
    }

    public void loadData(AboutUsBean datas) {
        tvContent.setText(Html.fromHtml(datas.getAbout_us()));
        tvEmail.setText(datas.getEmail());
        tvService.setText(datas.getService_qq());
    }

}
